<?php 
/*
# ------------------------------------------------------------------------
# JA Job Board Package
# ------------------------------------------------------------------------
# Copyright (C) 2004-2010 JoomlArt.com. All Rights Reserved.
# @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
# Author: JoomlArt.com
# Websites: http://www.joomlart.com - http://www.joomlancers.com.
# ------------------------------------------------------------------------
*/

?>
<?php  defined('_JEXEC') or die('Retricted Access');?>
<?php  global $jbconfig, $option;?>
	

<div id="jobboard-content">

<form name="adminForm" action="<?php echo JURI::root();?>index.php" method="GET" style="clear:both">
	<div class="moduletable clearfix" style="width:99%;">
		<h3>
			<span class="editlinktip hasTip" title="<?php echo JText::_('The number of credit you own will determine the posting amount that you can perform on site');  ?>"><?php echo JText::_('Buy Credit')?></span>
		</h3>
		<table class="tablelist creditlist">				
			<tr class="first">
				<td class="sectiontableheader"><?php echo JText::_("Credit Package Detail");?></td>
				<td class="sectiontableheader"><?php echo JText::_("Credit amount");?></td>
				<td class="sectiontableheader"><?php echo JText::_("Price").'('.$jbconfig['currency']->get('currency', '$').')';?></td>
			</tr>
			<?php if(isset( $this->package_credits)){ 
				$last = count($this->package_credits);
				
			?>
				<?php foreach ($this->package_credits as $k=>$row){
					if ($k==0)
			      		$classname = 'first sectiontableentry'.(($k%2)+1);
			      	elseif ($k==$last-1)
			      		$classname = 'last sectiontableentry'.(($k%2)+1);
			      	else 
			      		$classname = 'sectiontableentry'.(($k%2)+1);
				?>
					<tr class="<?php echo $classname; ?>">
						<td width="50%" class="first">
							<input type="radio" value="<?php echo $row->id;?>" name="cid[]" id="cid<?php echo $k?>"/> 
							<label for="cid<?php echo $k?>"><?php echo $row->title;?></label>
						</td>
						<td width="20%">
							<?php echo $row->value;?>
						</td>
						<td class="last">
							<?php echo $row->price;?>
							
						</td>
					</tr>
					
				<?php }?>
				
			<?php }?>
				
			<tr>
				<td>
					<b><?php echo JText::_('Payment method')?>:</b>
				</td>
				<td colspan="2">
					<?php if( isset($this->paysys) ) echo $this->paysys;?>
				</td>
			</tr>
			
			<tr class="last">						
				<td colspan="3">
					<input class="button" style="text-align:center" type="submit" value="<?php echo JText::_("Order Now")?>"/>
				</td>
			</tr>
		</table>			
	</div>	
	
	<input type="hidden" name="option" value="<?php echo $option; ?>" />
	<input type="hidden" name="view" value="japayment" />
	<input type="hidden" name="layout" value="credit_confirm" />
	<input type="hidden"  name="Itemid" value="<?php echo JRequest::getInt('Itemid', 0);?>" />	
	<?php echo JHTML::_( 'form.token' ); ?>	
 </form>
</div>